package com.zxy.demo.java;

import java.util.Date;

/**
 * Anonymous.
 * 
 * Created by zxybird on 17/1/4.
 */
public class Anonymous {

  // public static void main(String[] args) {
  // final Date now = new Date();
  // ISay say = new ISay() {
  // public void sayHello() {
  // System.out.println(now);
  // }
  // };
  // }

  public static void main(String[] args) {
    final Date now = new Date();
    ISay say = new ISay() {
      public void sayHello() {
        System.out.println(this);
      }
    };
  }

}

interface ISay {
  void sayHello();
}
